package ObjectVC;

import java.util.ArrayList;
import javax.swing.JOptionPane;

public aspect History {
	after(Object actualObj, Action action, ArrayList<Object> actionParams): 
		VCOperations.VCops(actualObj, action, actionParams) 
		&& if(action.equals(Action.History)){
		if (null != actionParams && actionParams.size()>0){
			Object obj = actionParams.get(0);

			if (null != obj){
				ArrayList<Version> list = DB.getVersionList(obj);
				if (null != list)
					showHistory(list);
			}
			JOptionPane.showMessageDialog(null, "Object is null");
		}
	}

	private void showHistory(ArrayList<Version> list) {
		// TODO Auto-generated method stub
		
	}
}
